package com.sky.mapper;

import com.sky.entity.AddressBook;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

@Mapper
public interface AddressMapper {
    void addAddress(AddressBook addressBook);

    List<AddressBook> list();
@Delete("delete from sky_take_out.address_book where id = #{id}")
    void deleteById(Long id);

    AddressBook selectById(Long id);

    void update(AddressBook addressBook);

    AddressBook getDefault();

    void updateByUserId(AddressBook addressBook);
}
